/**
 * <copyright>
 * </copyright>
 *
 * $Id$
 */
package uimigration.xmluimodel.impl;

import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.EPackage;

import org.eclipse.emf.ecore.impl.EFactoryImpl;

import org.eclipse.emf.ecore.plugin.EcorePlugin;

import uimigration.xmluimodel.Content;
import uimigration.xmluimodel.Property;
import uimigration.xmluimodel.XmluimodelFactory;
import uimigration.xmluimodel.XmluimodelPackage;

/**
 * <!-- begin-user-doc -->
 * An implementation of the model <b>Factory</b>.
 * <!-- end-user-doc -->
 * @generated
 */
public class XmluimodelFactoryImpl extends EFactoryImpl implements
		XmluimodelFactory {
	/**
	 * Creates the default factory implementation.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static XmluimodelFactory init() {
		try {
			XmluimodelFactory theXmluimodelFactory = (XmluimodelFactory) EPackage.Registry.INSTANCE
					.getEFactory("http://xmluimodel/1.0");
			if (theXmluimodelFactory != null) {
				return theXmluimodelFactory;
			}
		} catch (Exception exception) {
			EcorePlugin.INSTANCE.log(exception);
		}
		return new XmluimodelFactoryImpl();
	}

	/**
	 * Creates an instance of the factory.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public XmluimodelFactoryImpl() {
		super();
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public EObject create(EClass eClass) {
		switch (eClass.getClassifierID()) {
		case XmluimodelPackage.OBJECT:
			return createObject();
		case XmluimodelPackage.PROPERTY:
			return createProperty();
		case XmluimodelPackage.CONTENT:
			return createContent();
		default:
			throw new IllegalArgumentException("The class '" + eClass.getName()
					+ "' is not a valid classifier");
		}
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public uimigration.xmluimodel.Object createObject() {
		ObjectImpl object = new ObjectImpl();
		return object;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public Property createProperty() {
		PropertyImpl property = new PropertyImpl();
		return property;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public Content createContent() {
		ContentImpl content = new ContentImpl();
		return content;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public XmluimodelPackage getXmluimodelPackage() {
		return (XmluimodelPackage) getEPackage();
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @deprecated
	 * @generated
	 */
	public static XmluimodelPackage getPackage() {
		return XmluimodelPackage.eINSTANCE;
	}

} //XmluimodelFactoryImpl
